import Vue from 'vue'
import VueRouter from 'vue-router'

// 1. 引入页面组件
import Home from '../view/Home.vue'
// 或使用懒加载（推荐）：
// const Home = () => import('../views/Home.vue')

// 2. 注册路由插件
Vue.use(VueRouter)

// 3. 定义路由规则
const routes = [
    {
        path: '/',
        name: 'Home',
        component: Home
    },
    {
        path: '/AppCenterDetail',
        name: 'AppCenterDetail',
        component: () => import('../view/appCenterComponents/appCenterDetail.vue') // 应用中心详情
    },
    {
        path: '/AppCenter',
        name: 'AppCenter',
        component: () => import('../view/appCentre.vue') // 应用中心
    },
    {
        path: '/ApplicationOpenPlatform',
        name: 'ApplicationOpenPlatform',
        component: () => import('../view/applicationOpenPlatform.vue') // 应用开放平台
    },
    {
        path: '/AboutUs',
        name: 'AboutUs',
        component: () => import('../view/about-us.vue') // 关于我们
    }
    ,
    {
        path: '/IndustrySynergy',
        name: 'IndustrySynergy',
        component: () => import('../view/industrySynergy.vue') // 行业协通
    },
    {
        path: '/SupplyServices',
        name: 'SupplyServices',
        component: () => import('../view/productEmpowerment/supplyServices.vue') // 交易大厅
    },
    {
        path: '/ExpertResources',
        name: 'ExpertResources',
        component: () => import('../view/productEmpowerment/expertResources.vue') // 专家资源
    },
    {
        path: '/EnterpriseServiceProviders',
        name: 'EnterpriseServiceProviders',
        component: () => import('../view/productEmpowerment/enterpriseServiceProviders.vue') // 企业服务商
    },
    {
        path: '/ScientificInstitutions',
        name: 'ScientificInstitutions',
        component: () => import('../view/productEmpowerment/scientificInstitutions.vue') // 科研机构
    },
    {
        path: '/IndustrySolutions',
        name: 'IndustrySolutions',
        component: () => import('../view/empowermentCases/industrySolutions.vue') // 行业解决方案
    },
    {
        path: '/ScenarioSolutions',
        name: 'ScenarioSolutions',
        component: () => import('../view/empowermentCases/scenarioSolutions.vue') // 场景解决方案
    },
    {
        path: '/RegionalSolutions',
        name: 'RegionalSolutions',
        component: () => import('../view/empowermentCases/regionalSolutions.vue') // 区域解决方案
    },
    {
        path: '/SignUplogin',
        name: 'SignUplogin',
        component: () => import('../view/signUplogin.vue') // 登录
    },
    {
        path: '/UserRegistration',
        name: 'UserRegistration',
        component: () => import('../view/userRegistration.vue') // 注册
    },
    {
        path: '/PolicyType',
        name: 'PolicyType',
        component: () => import('../view/industrialPolicy/policyType.vue') // 政策类型
    },
    {
        path: '/PolicyTopics',
        name: 'PolicyTopics',
        component: () => import('../view/industrialPolicy/policyTopics.vue') // 政策专题
    },
    {
        path: '/PolicySector',
        name: 'PolicySector',
        component: () => import('../view/industrialPolicy/policySector.vue') // 政策部门
    },
    {
        path: '/IndustrialFinance',
        name: 'IndustrialFinance',
        component: () => import('../view/industrialFinance.vue') // 产业金融
    },
	
	
	
	// rui 250625
    {
        path: '/CompanyNewsList',
        name: 'CompanyNewsList',
        component: () => import('../view/listPages/companyNewsList.vue') // 产业金融
    },
    {
        path: '/CompanyNewsDetail',
        name: 'CompanyNewsDetail',
        component: () => import('../view/listPages/companyNewsDetail.vue') // 产业金融
    }
]

// 4. 创建路由实例
const router = new VueRouter({
    // mode: 'history', // 可选：去除URL中的#号
    mode: 'hash', // ycr 250621
    base: process.env.BASE_URL,
    routes
})

export default router